package com.system.outpatientsystem.mapper;

import com.system.outpatientsystem.pojo.Category;
import com.system.outpatientsystem.pojo.Doctor;
import com.system.outpatientsystem.pojo.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;
import java.util.Map;

@Mapper
public interface DoctorMapper {


    @Select("select * from doctor")
    List<Doctor> getAll();

    @Select("select * from category_table")
    List<Category> getCategory();

    @Select("select * from doctor where office = #{office}")
    List<Doctor> getDoctorsByOffice(String office);

    @Select("select * from doctor where id=#{doctorId}")

    Doctor findById(Integer doctorId);

    @Select("select * from doctor where phone = #{phone}")
    Doctor findByPhone(String phone);
}
